Fixed conversion detection for mario/doc's Cape #130
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
An individual on r/ssbm pointed out that cape is not detected at all for conversion and combo detection. This is due to cape not changing a character's action state on hit. A hitlag check would pick it up, but to maintain 0.2.0 compatibility i try to avoid that. Here are the checks i used:
lastAttackLanded
changing from previous to current frameThis should not only cover cape, but also some weird edge cases like fox's laser and phantom hits. The flaw of this is that if 2 of them happen in a row, last attack landed won't change so it'll be missed. That's pretty rare though, so the next check isn't 100% necessary if it turns out to be too far
Fully staled minimum damage cape does 3.15%. 3.1% is high enough that it won't trigger on magnifying glass or any form of pichu's self damage (which maxes out at 3%). The only other self damage i can think of that doesn't trigger any of the
isDamaged
states would be roy's fully charged neutral BAlternatively, a more targeted check could work. Cape doesn't change the recipient's state, but it does incur hitlag and pause the action state counter. Checking for a change in the action state counter would also resolve the magnifying glass bug. As a side note, cape doesn't turn you around instantly, so you can't use
facingDirection
to detect it unfortunately =(This isn't super well tested though, mainly because i have very few mario/doc replays laying around, and even fewer for most low tiers whose edge cases i'm probably forgetting. If y'all have some laying around, i'd be very grateful if you shot them my way. If not, i'll do my best to source a few hundred so i can test it fully before finalizing.